Societal Factors
A collection of visualizations to highlight how environmental and societal factors impact our mental well-being.
bar_slider = alt.Chart(df).mark_area().encode(
x='Year',
y='Population (historical estimates)',
color ='Country'
).properties(
height=300
).add_selection(select_year)
employ_scatter = alt.Chart(df).mark_circle().encode(
x='Depression (%)',
y='Employment rate',
color = 'Country',
opacity=alt.condition(
select_year,
alt.value(1), alt.value(0.1)
)
)
#best_line = scatter_plot.transform_regression('Depression (%)','Employement rate').mark_line()
(employ_scatter) & bar_slider